﻿using NHibernate.Mapping.Attributes;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace NHibernateStudy
{
    [Serializable]
    [Class(Table = "animals", Name = "NHibernateStudy.Animal,NHibernateStudy")]
    public class Animal
    {
        /// <summary>
        /// 主键
        /// </summary>
        [Id(Name = "Id", Column = "id", TypeType = typeof(string))]
        [Key]
        [Generator(Class = "uuid.hex")]
        public virtual String Id { get; set; }

        [Property(Name = "Name", Column = "name")]
        public virtual string Name { get; set; }
        
    }
}
